import {
	http
} from '../httpIndex.js'
export default {
	// 班级列表
	tecClassList(id) {
		return http.get(`app/Class/getClassListByTeacherId?loginId=${id}`)
	},
	// 班级考勤 app/ClassAttence/getAppClaStuAttenceListByCId?accessDate=2022-03-09&timeSlot=1&classId=7
	tecClassAttence(accessDate, timeSlot, classId) {
		return http.get(
			`app/ClassAttence/getAppClaStuAttenceListByCId?accessDate=${accessDate}&timeSlot=${timeSlot}&classId=${classId}`
		)
	},
	// 班级提交考勤记录/app/ClassAttence/createClassAttence
	createClassAttence(attenceDate, classId, statusArray, studentNoArray, timeSlot, createBy, isDuty) {
		return http.post('app/ClassAttence/createClassAttence', {
			attenceDate: attenceDate,
			classId: classId,
			statusArray: statusArray,
			studentNoArray: studentNoArray,
			timeSlot: timeSlot,
			createBy: createBy,
			isDuty: isDuty
		})
	},
	// 违纪登记/app/ClassDv/getAppClaStuAttenceListByCId
	getAppClaStuAttenceListByCId(classId, dvDate, timeSlot) {
		return http.get(
			`app/ClassDv/getAppClaStuAttenceListByCId?classId=${classId}&dvDate=${dvDate}&timeSlot=${timeSlot}`, )
	},
	// 违纪详情提交 /app/ClassDv/createClassDv
	createClassDv(classId, createBy, dvDate, dvTypeArray, studentNoArray, timeSlot) {
		return http.post('app/ClassDv/createClassDv', {
			createBy: createBy,
			classId: classId,
			dvDate: dvDate,
			dvTypeArray: dvTypeArray,
			studentNoArray: studentNoArray,
			timeSlot: timeSlot
		})
	},
	// 班级卫生提交 /app/ClassHygiene/createClassHygiene
	createClassHygiene(checkDate, classId, className, create_by, timeSlot, grade, id) {
		return http.post('app/ClassHygiene/createClassHygiene', {
			checkDate: checkDate,
			classId: classId,
			className: className,
			create_by: create_by,
			timeSlot: timeSlot,
			grade: grade,
			id: id
		})
	},
	// 查询班级卫生情况 /app/ClassHygiene/getAppClaHyByCId
	getAppClaHyByCId(accessDate, classId, timeSlot) {
		return http.get(
			`app/ClassHygiene/getAppClaHyByCId?accessDate=${accessDate}&classId=${classId}&timeSlot=${timeSlot}`)
	},
	// 班级报修列表 /app/ClassRepair/getAppClassRepairList
	getAppClassRepairList(classId) {
		return http.get(`app/ClassRepair/getAppClassRepairList?classId=${classId}`)
	},
	// 班级报修设备 /app/Repair/getAppDevice
	getAppDevice() {
		return http.get('app/Repair/getAppDevice')
	},
	// 提交班级报修 /app/ClassRepair/createClassRepair
	createClassRepairUpload(classId, createTime, deviceIds, photo, repairBy, repairDesc, status) {
		return http.post("app/ClassRepair/createClassRepair", {
			classId: classId,
			createTime: createTime,
			deviceIds: deviceIds,
			photo: photo,
			repairBy: repairBy,
			repairDesc: repairDesc,
			status: status
		})
	},
	// 查询班级宿舍请假 /app/Class/getClassStuListByCName
	getClassStuListByCName(className) {
		return http.get(`app/Class/getClassStuListByCName?className=${className}`)
	},
	// 提交班级宿舍请假 /app/StudentLeave/createUpdateStuLeaves
	createUpdateStuLeaves(classId, className, endDateArray, startDateArray, studentNameArray, leaveDays, phoneArray,
		studentNoArray, leaveId) {
		return http.post("app/StudentLeave/createUpdateStuLeaves", {
			classId: classId,
			className: className,
			endDateArray: endDateArray,
			startDateArray: startDateArray,
			studentNameArray: studentNameArray,
			leaveDays: leaveDays,
			phoneArray: phoneArray,
			studentNoArray: studentNoArray,
			leaveId: leaveId
		})
	},
	// 班级宿舍请假删除 /app/StudentLeave/deleteStuLeaves
	deleteStuLeaves(endDate, leaveId, startDate, studentNo) {
		return http.post(`app/StudentLeave/deleteStuLeaves`, {
			endDate: endDate,
			leaveId: leaveId,
			startDate: startDate,
			studentNo: studentNo
		})
	},
	// 请假历史记录 app/StudentLeave/getStuLeavesList
	getStuLeavesList(userName) {
		return http.post(`app/StudentLeave/getStuLeavesList`, {
			userName: userName
		})
	},
	// 修改请假记录 app/StudentLeave/updateStuLeaves
	updateStuLeaves(id, updateDesc, startDate, endDate) {
		return http.post("app/StudentLeave/updateStuLeaves", {
			id: id,
			updateDesc: updateDesc,
			startDate: startDate,
			endDate: endDate
		})
	},
	tecAttendanceClass(accessDate, classDeptId, timeSlot) {
		return http.get(
			`app/Class/getAppClassDeptAccDvByDeptId?accessDate=${accessDate}&classDeptId=${classDeptId}&timeSlot=${timeSlot}`
		)
	},
	// 班级卫生修改 /app/Hygiene/updateHygiene
	updateHygiene(grade, id, bdormitoryId, hygieneItemRecordList,checkDate) {
		return http.put(`app/Hygiene/updateHygiene`, {
			grade: grade,
			id: id,
			bdormitoryId: bdormitoryId,
			hygieneItemRecordList: hygieneItemRecordList,
			checkDate:checkDate,
		})

	},
	// 班级报修设备 app/ClassRepair/getAppClassDevice
	getAppClassDevice() {
		return http.get("app/ClassRepair/getAppClassDevice")
	},
}